﻿<?
	if(!$content_ripple) {
	echo "
		<script>
			window.alert('댓글 내용을 입력을 하셔야 저장되죠?');
			history.go(-1)
		</script>
		";
	}
	
	include "../dbconn.php";

	$regist_day=date("Y-m-d");
	$ip = $_SERVER["REMOTE_ADDR"];

	$sql="insert into ripple(parent, name, pwd, content, regist_day, ip)  values('$num', '$_REQUEST[name_ripple]', '$_REQUEST[pwd_ripple]', '$_REQUEST[content_ripple]', '$regist_day', '$ip')";

	mysql_query($sql, $connect);
	mysql_close();

	echo ("
		<script>
			top.loacation.href='../index.php';
		</script>
		");

	echo("<meta http-equiv='refresh' content='0; url=../index.php'>");
?>